<?php /* Smarty version 2.6.18, created on 2016-12-02 14:26:20
         compiled from message/m.class.list.tpl.php */ ?>
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<link href="mstatic/css/bootstrap.min.css"  type="text/css" rel="stylesheet">
<link href="mstatic/css/index.css" type="text/css" rel="stylesheet">
<title>期末学生评语</title>
</head>

<body>
<!--头部-->
<nav class="navbar navbar-default navbar-fixed-top  top" role="navigation">
  <div class="container-fluid">
    <div class="navbar-header" style=" width:100%;"> <a class="navbar-brand"  href="javascript:history.go(-1);" style=" width:100%;  padding-right:0px;"> <span class="glyphicon glyphicon-arrow-left white"></span> 
      <!--    <span class="glyphicon glyphicon-pause white" style="margin-left:2%;"></span>--> 
      <span class="white" style="margin-left:10%"><?php if ($this->_tpl_vars['message_type'] == 1): ?>期末学生评语<?php else: ?>学生日常记事<?php endif; ?></span> <span class="glyphicon glyphicon-user white" style="float:right"></span> </a> </div>
  </div>
  
  <!-- /.container-fluid --> 
</nav>
<!--头部 end--> 
<!--主体部分-->
<div class="container" style="margin-top:70px;">
  <div class="row" style="margin-top:10px;">
    <div class="col-sm-12 distance" >
	<div class="box-header with-border">
		<?php $_from = $this->_tpl_vars['appoint_lists']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['value']):
?>
			<a href="index.php?a=message.studentlist&class_id=<?php echo $this->_tpl_vars['value']['class_id']; ?>
&message_type=<?php echo $this->_tpl_vars['message_type']; ?>
"<?php if ($this->_tpl_vars['value']['class_id'] == $this->_tpl_vars['class_id']): ?> class="btn btn-primary" <?php else: ?> class="btn btn-default"<?php endif; ?>><?php echo $this->_tpl_vars['value']['class_name']; ?>
<?php echo $this->_tpl_vars['show_name']; ?>
</a>
		<?php endforeach; endif; unset($_from); ?>  
	</div>    
      <div class="form-group">
        <label for="inputEmail3" class="col-sm-2 control-label">年级</label>
        <div class="col-sm-10">
          <select class="form-control" name="grade_id" id="grade_id">
			<option value=""> 全部</option>
			<?php $_from = $this->_tpl_vars['grade_lists']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['value']):
?>
			<option value="<?php echo $this->_tpl_vars['value']['grade_id']; ?>
"<?php if ($this->_tpl_vars['value']['grade_id'] == $this->_tpl_vars['grade_id']): ?>selected<?php endif; ?>><?php echo $this->_tpl_vars['value']['grade_name']; ?>
</option>
			<?php endforeach; endif; unset($_from); ?>
		  </select> 
        </div>
      </div>
    </div>
    <div class="col-sm-12 distance" >
      <div class="form-group">
        <label for="inputEmail3" class="col-sm-2 control-label">班级</label>
        <div class="col-sm-10">
          <select class="form-control" name="class_id" id="class_id">
			<option value=""> 全部</option>
			<?php $_from = $this->_tpl_vars['class_lists']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['value']):
?>
			<option value="<?php echo $this->_tpl_vars['value']['class_id']; ?>
"<?php if ($this->_tpl_vars['value']['class_id'] == $this->_tpl_vars['class_id']): ?>selected<?php endif; ?>><?php echo $this->_tpl_vars['value']['class_name']; ?>
</option>
			<?php endforeach; endif; unset($_from); ?>
		  </select> 
        </div>
      </div>
    </div>
    <div class="col-sm-12 distance" >
      <div class="form-group">
        <div class="col-sm-10 text-center" >
		  <input type="hidden" name="a" value="message.studentlist">
          <button type="submit" class="btn btn-success" style="width:80%">搜索</button>
        </div>
      </div>
    </div>
  </div>
  <div class="row" style="margin-top:15px;margin-left:1px; margin-right:1px;">
  <?php $_from = $this->_tpl_vars['divide_lists']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['value']):
?>
    <table class="table table-striped table-bordered"  id="middles">
      <tr>
        <td>学号</td>
        <td><?php echo $this->_tpl_vars['value']['student_no']; ?>
</td>
      </tr>
      <tr>
        <td>姓名</td>
        <td><?php echo $this->_tpl_vars['value']['student_name']; ?>
</td>
      </tr>
      <tr>
        <td>评语内容</td>
        <td><?php echo $this->_tpl_vars['value']['message_content']; ?>
</td>
      </tr>
      <tr>
        <td>操作</td>
        <td>
			<a onClick="show('<?php echo $this->_tpl_vars['value']['student_no']; ?>
', '<?php echo $this->_tpl_vars['value']['student_name']; ?>
', '<?php echo $this->_tpl_vars['value']['student_id']; ?>
','<?php echo $this->_tpl_vars['value']['message_id']; ?>
','<?php echo $this->_tpl_vars['value']['message_content']; ?>
','<?php echo $this->_tpl_vars['value']['message_file']; ?>
')" href="#" class="btn btn-success btn-sm" data-toggle="modal" data-target="#myModal"  >编辑 </a>
            <a href="index.php?a=message.details&message_id=<?php echo $this->_tpl_vars['value']['message_id']; ?>
&student_id=<?php echo $this->_tpl_vars['value']['student_id']; ?>
&message_type=<?php echo $this->_tpl_vars['message_type']; ?>
" class="btn btn-warning btn-sm" >查看</a>
		</td>
      </tr>
      <!-- <tr>
        <td>座位</td>
        <td>姓名</td>
        <td>评语内容</td>
        <td  colspan="2">操作</td>
      </tr>
      <tr>
        <td>001</td>
        <td>沙发上</td>
        <td>供热如果仍</td>
        <td><a type="button" class="btn btn btn-warning" href="students_daily_chronicle_select.html">查看</a></td>
        <td><a type="button" class="btn btn-danger" data-toggle="modal" data-target="#myModal">添加</a></td>
      </tr>-->
    </table>
   <?php endforeach; endif; unset($_from); ?>     
  </div>
</div>
<!--弹出框-->
<div class="modal fade" id="myModal" tabindex="-1"  aria-labelledby="myModalLabel">
  <div class="modal-dialog" >
    <div class="modal-content">
         <form name="myform" method="post" action="" enctype="multipart/form-data">
              <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                <h4 class="modal-title" id="myModalLabel"><?php if ($this->_tpl_vars['message_type'] == 1): ?>期末学生评语<?php else: ?>学生日常记事<?php endif; ?></h4>
              </div>
              <div class="modal-body">
                    学号：<span id = "bbb"></span>  <span style="margin-left:20px;">姓名：</span><span id="ming"></span>
                    <div class="form-group" style="margin-top:16px;">
                        <p><?php if ($this->_tpl_vars['message_type'] == 1): ?>评语<?php else: ?>记事<?php endif; ?>内容:</p>
                        <textarea class="form-control" rows="3" name="message_content" id="fff"></textarea>
                    </div>
                    <div class="form-group" style="margin-top:16px;">

                        <p>附件：<span id="hhh"></span></p><input name="message_file" type="file">

                    </div>
              </div>
              <div class="modal-footer center-block">
			 
			    <input type="hidden" name="message_id" value="" id="ddd">
			    <input type="hidden" name="student_id" value="" id="ccc">
                <input type="submit" class="btn btn-primary" value="确定">
              </div>
          </form>
    </div>
  </div>
</div>
<!--container  end--> 
<!--主体部分  end--> 
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "m.index.footer.tpl.php", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
<script>

function show(a, b, c, d, f, h){
	
	$("#bbb").html(a);
	$("#ming").html(b);
	$("#ccc").val(c);
	$("#ddd").val(d);
	$("#fff").val(f);
	$("#hhh").html(h);
	}

</script>